home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / vampso1a / dock.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-08-29  |  2.1 KB  |  69 lines

  1. VERSION 5.00
  2. Begin VB.Form Form1 
  3.    BackColor       =   &H80000007&
  4.    BorderStyle     =   5  'Sizable ToolWindow
  5.    Caption         =   "Vampire Software: Docking Example"
  6.    ClientHeight    =   3195
  7.    ClientLeft      =   60
  8.    ClientTop       =   300
  9.    ClientWidth     =   4680
  10.    LinkTopic       =   "Form1"
  11.    MaxButton       =   0   'False
  12.    MinButton       =   0   'False
  13.    ScaleHeight     =   3195
  14.    ScaleWidth      =   4680
  15.    ShowInTaskbar   =   0   'False
  16.    StartUpPosition =   3  'Windows Default
  17.    Begin VB.CommandButton Command1 
  18.       Caption         =   "Dock"
  19.       Height          =   615
  20.       Left            =   240
  21.       TabIndex        =   1
  22.       Top             =   2520
  23.       Width           =   4215
  24.    End
  25.    Begin VB.Label Label2 
  26.       Alignment       =   2  'Center
  27.       Appearance      =   0  'Flat
  28.       BackColor       =   &H80000005&
  29.       BorderStyle     =   1  'Fixed Single
  30.       Caption         =   "Http://zap.to/vampsoft/"
  31.       ForeColor       =   &H00000000&
  32.       Height          =   255
  33.       Left            =   240
  34.       TabIndex        =   2
  35.       Top             =   2160
  36.       Width           =   4215
  37.    End
  38.    Begin VB.Label Label1 
  39.       Alignment       =   2  'Center
  40.       Appearance      =   0  'Flat
  41.       BackColor       =   &H80000005&
  42.       BorderStyle     =   1  'Fixed Single
  43.       Caption         =   $"Dock.frx":0000
  44.       ForeColor       =   &H80000008&
  45.       Height          =   845
  46.       Left            =   120
  47.       TabIndex        =   0
  48.       Top             =   120
  49.       Width           =   4455
  50.    End
  51. Attribute VB_Name = "Form1"
  52. Attribute VB_GlobalNameSpace = False
  53. Attribute VB_Creatable = False
  54. Attribute VB_PredeclaredId = True
  55. Attribute VB_Exposed = False
  56. Private Sub Command1_Click()
  57. Dim ScreenX, ScreenY As Integer
  58. ScreenY = Screen.Height
  59. ScreenX = Screen.Width
  60. If Me.Top <= 200 Then Me.Top = 0
  61. If Me.Left <= 200 Then Me.Left = 0
  62. If Me.Left >= ScreenX - Me.Width - 200 Then
  63.     Me.Left = ScreenX - Me.Width
  64. End If
  65. If Me.Top >= ScreenY - Me.Height - 200 Then
  66.     Me.Top = ScreenY - Me.Height - 420
  67. End If
  68. End Sub
  69.